import redis
from redis import ConnectionPool

POOL = ConnectionPool(
    host='127.0.0.1',
    port=6379,
    max_connections=10,
    encoding="utf-8",
    decode_responses=True,
    db=0,
)


def get_redis_connect():
    """

    :return:  redis connect
    """
    return redis.Redis(connection_pool=POOL)
